<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<title></title>
		<link rel="stylesheet" type="text/css" href="css/common.css" />
		<link rel="stylesheet" type="text/css" href="css/ShopNothing.css" />
		<link rel="stylesheet" type="text/css" href="css/ShowCart.css" />
	</head>

	<body>
		<!--顶部导航开始-->
		<div class="site_nav">
			<div class="center clearfix">
				<ul class="center_ul_l clearfix">
					<li class="li1">
						<a href="#">
							<span></span> 收藏花礼网
						</a>
					</li>
					<li class="li2 por">
						<a href="#">
							<span></span> 关注微信
						</a>
						<div class="line poa">
						</div>
						<div class="dropdown poa">
							<img src="img/wechat_qrcode.jpg" />
							<p>扫码关注<br>回复"礼物" 更多惊喜！</p>
						</div>
					</li>
					<li class="li3 por">
						<a href="#">
							<span></span> 手机花礼
						</a>
						<div class="line poa">
						</div>
						<div class="dropdown poa">
							<img src="img/wechat_qrcode.jpg" />
							<p>首单再减20！<br/>(需输入券号9920)</p>
						</div>
					</li>
				</ul>

				<ul class="center_ul_r clearfix">
					<li class="li1">
						<a href="login.php">您好，<span>请登录</span></a>
					</li>
					<li class="site_nav_pipe"></li>
					<li class="li2">
						<a class="register" href="register.php">注册</a>
						<a class="out" href="javascript:void(0)">退出</a>
					</li>
					<li class="site_nav_pipe"></li>
					<li class="li3">
						<a href="dingdan.php">订单查询</a>
					</li>
					<li class="site_nav_pipe"></li>
					<li class="li5 por">
						<a href="#">
							客户服务
							<i></i>
						</a>
						<div class="line poa">
						</div>
						<div class="dropdown poa">
							<a href="#">在线付款</a>
							<a href="#">帮助中心</a>
							<a href="#">售后服务</a>
							<a href="#">配送范围</a>
							<a href="#">留言反馈</a>
						</div>
					</li>
					<li class="site_nav_pipe"></li>
					<li class="li6 por">
						<a href="javascript:void(0)">
							<span></span> 购物车
							<?php
				                require_once 'dbConn.php';
				                date_default_timezone_set("PRC");
	                            
	                            $username = !empty($_COOKIE['huausername']) ? $_COOKIE['huausername'] : null;
	                                           
	                            $sql = "select * from user_shop where userid =(select id from user where email = '". $username ."')"; 

	                            $result = mysql_query($sql,$con);
	                            $num_rows = mysql_num_rows($result);
	                            echo "<p class = \"cart_num\">(". $num_rows .")</p>";
					         ?>
							<i></i>
						</a>
						<div class="line poa">
						</div>
						<div class="dropdown_cart poa" id="dropdown_cart">
							<div class="empty">您的购物车中没有商品，
								<a href="#">先去选购吧</a>！</div>
						</div>
					</li>
					<li class="site_nav_pipe"></li>
					<li class="li7">
						<p>中国鲜花礼品网:中国鲜花网领先品牌</p>
					</li>
				</ul>
			</div>
		</div>
		<!--顶部导航结束-->

		<!--头部开始-->
		<div class="header">
			<div class="center">
				<div class="logo">
					<h1>
                  	  <a href="index.php"><img src="img/logo.png"/></a>   
                      <span class="wwww-name">花礼网</span>
					</h1>
					<i></i>
					<h2>中国鲜花礼品网 始于2005，简称花礼网</h2>
				</div>
				<div class="service">
					<span class="ico_phone"></span>400-889-8188
					<span class="line">|</span>
					<span class="ico_headset"></span>
					<a href="#">在线客服</a>
				</div>
			</div>
		</div>
		<!--头部结束-->

		<!--购物车列表开始-->
		<div class="cart_panel">
			<div class="center">
				<div class="hd">
					<ul class="title clearfix">
						<li class="product">商品名称</li>
						<li class="market-price">市场价</li>
						<li class="order-price">订购价</li>
						<li class="num">数量</li>
						<li class="operate">操作</li>
					</ul>
				</div>

				<div class="bd">

					<?php
	                  require_once 'dbConn.php';
	                  date_default_timezone_set("PRC");
	                  
	                  $username = !empty($_COOKIE['huausername']) ? $_COOKIE['huausername'] : null;
	                  
	                  $sql = "select * from user_shop where userid =(select id from user where email = '". $username ."')"; 
	                  $result = mysql_query($sql,$con);
	                  $shopList = '';
	                  while($rs = mysql_fetch_array($result)){
	                        $shopList[] = $rs;
	                  }
	                  
	                  // 循环商品列表
	                 if(mysql_affected_rows()>0){
	                   foreach ($shopList as $shop){
	                  	echo "
	                  	<ul class=\"order_list clearfix\" shop_id=". $shop["Id"] .">
	                  		<li class=\"img_box\">
							    <a href=\"#\">
								    <img src=". $shop["pic"] ." />
							    </a>
						    </li>
						    <li class=\"product\">   
							    <a href=\"#\">
								    <span class=\"product_title\">". $shop["name"] ."</span>
							    </a>
						    </li>
						    <li class=\"market_price\">
							    <span class=\"price_sign\">¥</span>
								<span class=\"price_num\">". $shop["price"] ."</span>
							</li>
							<li class=\"order_price\">
								<span class=\"price_sign\">¥</span>
								<span class=\"price_num\" shop_id=". $shop["Id"] .">". $shop["price"] ."</span>
							</li>
							<li class=\"num\">
								<div class=\"input_num\">
									<a href=\"javascript:void(0)\" class=\"btn_default btn_remove\" shop_id=". $shop["Id"] ."><i class=\"ico_minus\"></i></a>
									<input type=\"text\" class=\"form_control\" shop_id=". $shop["Id"] ." value=". $shop["number"] ." maxlength=\"2\" />
									<a href=\"javascript:void(0)\" class=\"btn_default btn_add\" shop_id=". $shop["Id"] ."><i class=\"ico_add\"></i></a>
								</div>
							</li>
							<li class=\"operate\">
								<a href=\"javascript:void(0)\" class=\"remove\">删除</a><br>
								<a href=\"#\">移到我的关注</a>
							</li>    
	                    </ul>
	                  	";
	                   }
	                 }
                    ?>
				</div>
			</div>
		</div>
		<!--购物车列表结束-->

		<!--结算开始-->
		<div class="set_bar ">
			<div class="center clearfix ">
				<div class="set_info ">
					<a class="back " href="# ">
						<span class="ico_back "></span>继续挑选
					</a>
					<div class="set_stat ">
						应付金额:
						<div class="price ">
							<span class="price_sign">¥</span>
							<span class="price_num">239</span>
						</div>
					</div>

				</div>
				<button class="btn_primary " type="button ">去结算</button>
			</div>
		</div>
		<!--结算结束-->

		<!--tab切换开始-->
		<div class="cart_tabs ">
			<div class="center ">
				<div class="title ">
					购买该商品的还购买了
				</div>
				<div class="tab1 por ">
					<div class="owl_prev poa "></div>
					<div class="owl_next poa "></div>
					<div class="tab_center clearfix por ">
						<ul class="clearfix poa ">
							<li>
								<a href="# ">
									<img src="img/car_pic_01.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/999纯金箔玫瑰+陶瓷花瓶一千足金箔玫瑰</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">132</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_02.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/十八音水晶钢琴一水晶音乐盒 韵升精品机芯</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">218</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_03.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/宝石旋转木马/蓝一音乐盒畅销款 送女友表白</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">152</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_04.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/奢悦之美巧克力礼盒一夹心巧克力</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">150</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_05.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/Laderach 思念TA礼盒一瑞士进口巧克力礼盒</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">215</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_06.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/海之恋一永生花盒：厄瓜多尔进口蓝色永生</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">428</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_07.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/芭蕾舞女孩永生花礼盒一粉色化妆镜+永生玫</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">370</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
							<li>
								<a href="# ">
									<img src="img/car_pic_08.jpg " />
								</a>
								<div class="ti ">
									<a href="# " target="_blank ">顺丰包邮/3D水晶内雕玫瑰花一激光内雕水晶工艺品</a>
								</div>
								<div class="price ">
									<span class="price_sign ">¥</span>
									<span class="price_num ">102</span>
								</div>
								<div class="operate ">
									<a href="# " class="add_cart ">加入购物车</a>
								</div>
							</li>
						</ul>
					</div>
				</div>
			</div>
		</div>
		<!--tab切换结束-->

		<!--服务开始-->
		<div class="toper_server">
			<div class="center clearfix">
				<ul>
					<li class="li1">
						<span class="icon1"></span>
						<h4>鲜花电商龙头</h4>
						<p>销量领先，权威认证龙头企业</p>
					</li>
					<li class="li2">
						<span class="icon1"></span>
						<h4>11年品牌 真实口碑</h4>
						<p>最近评价185807条</p>
					</li>
					<li class="li3">
						<span class="icon1"></span>
						<h4>鲜花实拍秀展示</h4>
						<p>敢展现送前实拍的鲜花网</p>
					</li>
					<li class="li4">
						<span class="icon1"></span>
						<h4>3小时送花</h4>
						<p>全国连锁，3小时送1000城市</p>
					</li>
				</ul>
			</div>
		</div>
		<!--服务结束-->

		<!--尾部导航开始-->
		<div class="footer_nav">
			<div class="center">
				<ul class="clearfix">
					<li>
						<a href="#">首页</a>
					</li>
					<li>
						<a href="#">关于我们</a>
					</li>
					<li>
						<a href="#">媒体报道</a>
					</li>
					<li>
						<a href="#">联系方式</a>
					</li>
					<li>
						<a href="#">企业团购</a>
					</li>
					<li>
						<a href="#">花店加盟</a>
					</li>
					<li>
						<a href="#">在线补款</a>
					</li>
					<li>
						<a href="#">为什么选择中国鲜花礼品网</a>
					</li>
				</ul>
			</div>
		</div>
		<!--尾部导航结束-->

		<!--合作商开始-->
		<div class="auth">
			<div class="center">
				<a href="#"><img src="img/hezuo_01.jpg" /></a>
				<a href="#"><img src="img/hezuo_02.jpg" /></a>
				<a href="#"><img src="img/hezuo_03.jpg" /></a>
				<a href="#"><img src="img/hezuo_04.jpg" /></a>
				<a href="#"><img src="img/hezuo_05.jpg" /></a>
				<a href="#"><img src="img/hezuo_06.jpg" /></a>
			</div>
		</div>
		<!--合作商结束-->

		<!--版权开始-->
		<div class="copyright">
			<div class="center clearfix">
				<p>
					<a href="#">中国花卉协会会员</a>
					<a href="#">中国电子商务协会会员</a>
					ICP经营许可证：
					<a href="#">粤B2-20050744</a>
					<a href="#">粤ICP备09171662号</a>
					Copyright © 2005-2016
				</p>
				<p>
					花礼网 （中国鲜花礼品网）
					<a href="#">www.hua.com</a>
					中国鲜花网领先品牌，鲜花速递专家！
				</p>
			</div>
		</div>
		<!--版权结束-->

	</body>
	<script type="text/javascript " src="js/jquery-1.11.3.js "></script>
	<script type="text/javascript " src="js/common.js "></script>
	<script type="text/javascript " src="js/ShowCart.js "></script>

</html>